beswarm 0.2.76__py3-none-any.whl → 0.2.77__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -275,6 +275,11 @@ async def fetch_gpt_response_stream(client, url, headers, payload, timeout):
275
275
 
276
276
  no_stream_content = safe_get(line, "choices", 0, "message", "content", default=None)
277
277
  openrouter_reasoning = safe_get(line, "choices", 0, "delta", "reasoning", default="")
278
+ openrouter_base64_image = safe_get(line, "choices", 0, "delta", "images", 0, "image_url", "url", default="")
279
+ if openrouter_base64_image:
280
+ sse_string = await generate_sse_response(timestamp, payload["model"], content=f"\n\n![image]({openrouter_base64_image})")
281
+ yield sse_string
282
+ continue
278
283
  azure_databricks_claude_summary_content = safe_get(line, "choices", 0, "delta", "content", 0, "summary", 0, "text", default="")
279
284
  azure_databricks_claude_signature_content = safe_get(line, "choices", 0, "delta", "content", 0, "summary", 0, "signature", default="")
280
285
  # print("openrouter_reasoning", repr(openrouter_reasoning), openrouter_reasoning.endswith("\\\\"), openrouter_reasoning.endswith("\\"))
@@ -844,6 +844,9 @@ class chatgpt(BaseLLM):
844
844
  except BadRequestError as e:
845
845
  self.logger.error(f"Bad request error: {e}")
846
846
  raise
847
+ except GeneratorExit:
848
+ self.logger.warning("GeneratorExit caught, closing stream.")
849
+ break
847
850
  except ValidationError as e:
848
851
  self.logger.warning(f"Validation failed: {e}. Retrying with corrective prompt.")
849
852
  need_done_prompt = [
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: beswarm
3
- Version: 0.2.76
3
+ Version: 0.2.77
4
4
  Summary: MAS
5
5
  Requires-Python: >=3.11
6
6
  Description-Content-Type: text/markdown
@@ -12,7 +12,7 @@ beswarm/aient/aient/core/__init__.py,sha256=NxjebTlku35S4Dzr16rdSqSTWUvvwEeACe8K
12
12
  beswarm/aient/aient/core/log_config.py,sha256=kz2_yJv1p-o3lUQOwA3qh-LSc3wMHv13iCQclw44W9c,274
13
13
  beswarm/aient/aient/core/models.py,sha256=KMlCRLjtq1wQHZTJGqnbWhPS2cHq6eLdnk7peKDrzR8,7490
14
14
  beswarm/aient/aient/core/request.py,sha256=QnDhyrjzcJOEQU2oauMQi_HHMRR5NxdkrX7nn5JMwTc,76675
15
- beswarm/aient/aient/core/response.py,sha256=is1BaTJd0p6_xt2rpGjRtoyOWBqJWvufd15k-qDlqzM,35912
15
+ beswarm/aient/aient/core/response.py,sha256=HcyOEfZXZEXeJaUBMCYE4LiLyB79XuUR5o0Gtwdyi-E,36309
16
16
  beswarm/aient/aient/core/utils.py,sha256=sLmPHONYhIPq1zUYcbKOtIOpAVsLFk_5lNwH5-G2c4E,30013
17
17
  beswarm/aient/aient/core/test/test_base_api.py,sha256=pWnycRJbuPSXKKU9AQjWrMAX1wiLC_014Qc9hh5C2Pw,524
18
18
  beswarm/aient/aient/core/test/test_geminimask.py,sha256=HFX8jDbNg_FjjgPNxfYaR-0-roUrOO-ND-FVsuxSoiw,13254
@@ -21,7 +21,7 @@ beswarm/aient/aient/core/test/test_payload.py,sha256=8jBiJY1uidm1jzL-EiK0s6UGmW9
21
21
  beswarm/aient/aient/models/__init__.py,sha256=ZTiZgbfBPTjIPSKURE7t6hlFBVLRS9lluGbmqc1WjxQ,43
22
22
  beswarm/aient/aient/models/audio.py,sha256=kRd-8-WXzv4vwvsTGwnstK-WR8--vr9CdfCZzu8y9LA,1934
23
23
  beswarm/aient/aient/models/base.py,sha256=-nnihYnx-vHZMqeVO9ljjt3k4FcD3n-iMk4tT-10nRQ,7232
24
- beswarm/aient/aient/models/chatgpt.py,sha256=-3bOA_jLsePy3B77Q5C1C3UglY0NDc9dRMDi7bAdcNw,47056
24
+ beswarm/aient/aient/models/chatgpt.py,sha256=R6qXgTbcshwYKx3nfSgh4uK2baQ6OZ37j8zV_wV8lLk,47189
25
25
  beswarm/aient/aient/plugins/__init__.py,sha256=p3KO6Aa3Lupos4i2SjzLQw1hzQTigOAfEHngsldrsyk,986
26
26
  beswarm/aient/aient/plugins/arXiv.py,sha256=yHjb6PS3GUWazpOYRMKMzghKJlxnZ5TX8z9F6UtUVow,1461
27
27
  beswarm/aient/aient/plugins/config.py,sha256=TGgZ5SnNKZ8MmdznrZ-TEq7s2ulhAAwTSKH89bci3dA,7079
@@ -116,7 +116,7 @@ beswarm/tools/search_web.py,sha256=NYrb5KL_WUGPm-fOKT8Cyjon04lxBU-gaLdrVjeYgGo,1
116
116
  beswarm/tools/subtasks.py,sha256=OclAorPuuG9vnySoBN2ISzzoInZJV3wmLAVzdMF3FXM,10220
117
117
  beswarm/tools/worker.py,sha256=_cSkRUKRJMAiZiTfnBze_e9Kc7k7KvbB5hdxdvp4FW4,2009
118
118
  beswarm/tools/write_csv.py,sha256=u0Hq18Ksfheb52MVtyLNCnSDHibITpsYBPs2ub7USYA,1466
119
- beswarm-0.2.76.dist-info/METADATA,sha256=wHBsBp6jbdtdjKFr8bYWsDE7hOUBg0RY6erwkiP3yMQ,3878
120
- beswarm-0.2.76.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
121
- beswarm-0.2.76.dist-info/top_level.txt,sha256=pJw4O87wvt5882smuSO6DfByJz7FJ8SxxT8h9fHCmpo,8
122
- beswarm-0.2.76.dist-info/RECORD,,
119
+ beswarm-0.2.77.dist-info/METADATA,sha256=PKJty4NePxrtiZZ_yZMwA_j0ra5H1q2Am22x6DDM4t4,3878
120
+ beswarm-0.2.77.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
121
+ beswarm-0.2.77.dist-info/top_level.txt,sha256=pJw4O87wvt5882smuSO6DfByJz7FJ8SxxT8h9fHCmpo,8
122
+ beswarm-0.2.77.dist-info/RECORD,,